import type { MessageHandler, MessageOptions } from 'element-plus'
import { ElMessage } from 'element-plus'
/**
 * 对elementPlus 消息提示进行封装，方便统一样式
 * @param options MessageOptions
 * @returns MessageHandler
 */
export function Message(options: MessageOptions): MessageHandler {
  if (options.plain === undefined) {
    options.plain = true
  }

  return ElMessage(options)
}
